/*
package com.lixinxin.commoncomposeproject.network

import com.squareup.moshi.Moshi
import com.squareup.moshi.kotlin.reflect.KotlinJsonAdapterFactory
import retrofit2.Retrofit
import retrofit2.converter.moshi.MoshiConverterFactory
import retrofit2.http.GET
import retrofit2.http.Path
import retrofit2.http.Query

*/
/**
 *   author ： lixinxin
 *   time    ： 2021-11-19
 *   email：895330766@qq.com
 *//*

interface ApiService {

    // 1.首页相关
    // 1.1首页文章列表
    @GET("article/list/{page}/json")
    suspend fun articleList(
        @Path("page") page: Int,
        @Query("page_size") page_size: Int = 20
    ): ArticleModel


    companion object {

        val moshi = Moshi.Builder().addLast(KotlinJsonAdapterFactory()).build()

        val instance: ApiService by lazy {

            val retrofit = Retrofit.Builder()
                .baseUrl("https://www.wanandroid.com")
                .addConverterFactory(MoshiConverterFactory.create(moshi))
                .build()

            retrofit.create(ApiService::class.java)
        }

    }

}*/
